package abstractFactoryPattern;

/**
 * @author Yin_JC
 * @PackageName:abstractFactoryPattern
 * @Class:Client
 * @Description:
 * @date 2020/4/2 15:04
 */

public class Client {
    public static void main(String[] args) throws ClassNotFoundException, IllegalAccessException, InstantiationException {
        Class c = Class.forName("abstractFactoryPattern.Factory1");
        Object j = c.newInstance();
        Factory1 factory1 = (Factory1) j;
        factory1.refrigeratorProduce().use();
        factory1.toolProduce().fun();
        factory1.tvProduce().play();
    }
}
